package cate.common.table.activity.customwarorder.row;

import cate.common.table.EExcelNoteField;
import cate.common.table.EExcelRowClass;
import cate.common.table.ERow;
import cate.common.table.d.GDWarOrder;

@EExcelRowClass(IDTitle = "配置ID")
public class CustomWarorderBaseRow extends ERow {
    @EExcelNoteField(fieldName = "活动名称ID")
    public int nameId;

    @EExcelNoteField(fieldName = "基础充值项")
    public int basePayItemId;

    @EExcelNoteField(fieldName = "差额充值项")
    public int upGradePayItemId;

    @EExcelNoteField(fieldName = "进阶充值项")
    public int advancePayItemId;

    @EExcelNoteField(fieldName = "邮件ID")
    public int mailId;

    @EExcelNoteField(fieldName = "跑马灯ID")
    public int noticeId;

    @EExcelNoteField(fieldName = "经验道具ID")
    public int expItemId;

    @EExcelNoteField(fieldName = "战令币ID")
    public int tokenItemId;

    @EExcelNoteField(fieldName = "购买经验消耗")
    public String buyExpCostStr;

    @EExcelNoteField(fieldName = "购买经验增加")
    public int buyExp;

    @EExcelNoteField(fieldName = "附加宝箱奖励")
    public String exBoxRwdStr;

    @EExcelNoteField(fieldName = "附加宝箱经验")
    public int exBoxExpRequierd;

    @EExcelNoteField(fieldName = "等级分组")
    public int levelGroup;

    @EExcelNoteField(fieldName = "任务分组")
    public int taskGroup;

    @EExcelNoteField(fieldName = "商城分组")
    public int mallGroup;

    @EExcelNoteField(fieldName = "商城经验道具ID")
    public int mallExpItem;

    @EExcelNoteField(fieldName = "自选分组")
    public int chooseGroup;

    public byte getPayItemType(int payItemId) {
        if (payItemId == basePayItemId) {
            return GDWarOrder.PayItemType.BASE;
        }
        if (payItemId == upGradePayItemId) {
            return GDWarOrder.PayItemType.UPGRADE;
        }
        if (payItemId == advancePayItemId) {
            return GDWarOrder.PayItemType.ADVANCE;
        }
        return GDWarOrder.PayItemType.NONE;
    }

}
